/**
 * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package slcu.service.persistence;

import com.liferay.portal.service.persistence.BasePersistence;

import slcu.model.PersonalDelMinisterio;

/**
 * The persistence interface for the PersonalDelMinisterio service.
 *
 * <p>
 * Caching information and settings can be found in <code>portal.properties</code>
 * </p>
 *
 * @author tito
 * @see PersonalDelMinisterioPersistenceImpl
 * @see PersonalDelMinisterioUtil
 * @generated
 */
public interface PersonalDelMinisterioPersistence extends BasePersistence<PersonalDelMinisterio> {
	/*
	 * NOTE FOR DEVELOPERS:
	 *
	 * Never modify or reference this interface directly. Always use {@link PersonalDelMinisterioUtil} to access the PersonalDelMinisterio persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
	 */

	/**
	* Caches the PersonalDelMinisterio in the entity cache if it is enabled.
	*
	* @param personalDelMinisterio the PersonalDelMinisterio
	*/
	public void cacheResult(
		slcu.model.PersonalDelMinisterio personalDelMinisterio);

	/**
	* Caches the PersonalDelMinisterios in the entity cache if it is enabled.
	*
	* @param personalDelMinisterios the PersonalDelMinisterios
	*/
	public void cacheResult(
		java.util.List<slcu.model.PersonalDelMinisterio> personalDelMinisterios);

	/**
	* Creates a new PersonalDelMinisterio with the primary key. Does not add the PersonalDelMinisterio to the database.
	*
	* @param personalId the primary key for the new PersonalDelMinisterio
	* @return the new PersonalDelMinisterio
	*/
	public slcu.model.PersonalDelMinisterio create(long personalId);

	/**
	* Removes the PersonalDelMinisterio with the primary key from the database. Also notifies the appropriate model listeners.
	*
	* @param personalId the primary key of the PersonalDelMinisterio
	* @return the PersonalDelMinisterio that was removed
	* @throws slcu.NoSuchPersonalDelMinisterioException if a PersonalDelMinisterio with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio remove(long personalId)
		throws com.liferay.portal.kernel.exception.SystemException,
			slcu.NoSuchPersonalDelMinisterioException;

	public slcu.model.PersonalDelMinisterio updateImpl(
		slcu.model.PersonalDelMinisterio personalDelMinisterio, boolean merge)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the PersonalDelMinisterio with the primary key or throws a {@link slcu.NoSuchPersonalDelMinisterioException} if it could not be found.
	*
	* @param personalId the primary key of the PersonalDelMinisterio
	* @return the PersonalDelMinisterio
	* @throws slcu.NoSuchPersonalDelMinisterioException if a PersonalDelMinisterio with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio findByPrimaryKey(long personalId)
		throws com.liferay.portal.kernel.exception.SystemException,
			slcu.NoSuchPersonalDelMinisterioException;

	/**
	* Returns the PersonalDelMinisterio with the primary key or returns <code>null</code> if it could not be found.
	*
	* @param personalId the primary key of the PersonalDelMinisterio
	* @return the PersonalDelMinisterio, or <code>null</code> if a PersonalDelMinisterio with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio fetchByPrimaryKey(long personalId)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns all the PersonalDelMinisterios where mail = &#63;.
	*
	* @param mail the mail
	* @return the matching PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<slcu.model.PersonalDelMinisterio> findByMail(
		java.lang.String mail)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns a range of all the PersonalDelMinisterios where mail = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param mail the mail
	* @param start the lower bound of the range of PersonalDelMinisterios
	* @param end the upper bound of the range of PersonalDelMinisterios (not inclusive)
	* @return the range of matching PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<slcu.model.PersonalDelMinisterio> findByMail(
		java.lang.String mail, int start, int end)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns an ordered range of all the PersonalDelMinisterios where mail = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param mail the mail
	* @param start the lower bound of the range of PersonalDelMinisterios
	* @param end the upper bound of the range of PersonalDelMinisterios (not inclusive)
	* @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
	* @return the ordered range of matching PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<slcu.model.PersonalDelMinisterio> findByMail(
		java.lang.String mail, int start, int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the first PersonalDelMinisterio in the ordered set where mail = &#63;.
	*
	* @param mail the mail
	* @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
	* @return the first matching PersonalDelMinisterio
	* @throws slcu.NoSuchPersonalDelMinisterioException if a matching PersonalDelMinisterio could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio findByMail_First(
		java.lang.String mail,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException,
			slcu.NoSuchPersonalDelMinisterioException;

	/**
	* Returns the first PersonalDelMinisterio in the ordered set where mail = &#63;.
	*
	* @param mail the mail
	* @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
	* @return the first matching PersonalDelMinisterio, or <code>null</code> if a matching PersonalDelMinisterio could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio fetchByMail_First(
		java.lang.String mail,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the last PersonalDelMinisterio in the ordered set where mail = &#63;.
	*
	* @param mail the mail
	* @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
	* @return the last matching PersonalDelMinisterio
	* @throws slcu.NoSuchPersonalDelMinisterioException if a matching PersonalDelMinisterio could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio findByMail_Last(
		java.lang.String mail,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException,
			slcu.NoSuchPersonalDelMinisterioException;

	/**
	* Returns the last PersonalDelMinisterio in the ordered set where mail = &#63;.
	*
	* @param mail the mail
	* @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
	* @return the last matching PersonalDelMinisterio, or <code>null</code> if a matching PersonalDelMinisterio could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio fetchByMail_Last(
		java.lang.String mail,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the PersonalDelMinisterios before and after the current PersonalDelMinisterio in the ordered set where mail = &#63;.
	*
	* @param personalId the primary key of the current PersonalDelMinisterio
	* @param mail the mail
	* @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
	* @return the previous, current, and next PersonalDelMinisterio
	* @throws slcu.NoSuchPersonalDelMinisterioException if a PersonalDelMinisterio with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public slcu.model.PersonalDelMinisterio[] findByMail_PrevAndNext(
		long personalId, java.lang.String mail,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException,
			slcu.NoSuchPersonalDelMinisterioException;

	/**
	* Returns all the PersonalDelMinisterios.
	*
	* @return the PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<slcu.model.PersonalDelMinisterio> findAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns a range of all the PersonalDelMinisterios.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of PersonalDelMinisterios
	* @param end the upper bound of the range of PersonalDelMinisterios (not inclusive)
	* @return the range of PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<slcu.model.PersonalDelMinisterio> findAll(int start,
		int end) throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns an ordered range of all the PersonalDelMinisterios.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of PersonalDelMinisterios
	* @param end the upper bound of the range of PersonalDelMinisterios (not inclusive)
	* @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
	* @return the ordered range of PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<slcu.model.PersonalDelMinisterio> findAll(int start,
		int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Removes all the PersonalDelMinisterios where mail = &#63; from the database.
	*
	* @param mail the mail
	* @throws SystemException if a system exception occurred
	*/
	public void removeByMail(java.lang.String mail)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Removes all the PersonalDelMinisterios from the database.
	*
	* @throws SystemException if a system exception occurred
	*/
	public void removeAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the number of PersonalDelMinisterios where mail = &#63;.
	*
	* @param mail the mail
	* @return the number of matching PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public int countByMail(java.lang.String mail)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Returns the number of PersonalDelMinisterios.
	*
	* @return the number of PersonalDelMinisterios
	* @throws SystemException if a system exception occurred
	*/
	public int countAll()
		throws com.liferay.portal.kernel.exception.SystemException;
}